<link type="text/css" href="https://cdn.bootcdn.net/ajax/libs/amazeui/2.7.2/css/amazeui.min.css" rel="stylesheet">
<script type="text/javascript" src="https://cdn.bootcdn.net/ajax/libs/amazeui/2.7.2/js/amazeui.min.js"></script>



<!-- 文档地址 http://amazeui.shopxo.net/javascript/modal/ -->
<button
type="button"
class="am-btn am-btn-success"
id="doc-prompt-toggle">
内容窗
</button>
<div class="am-modal am-modal-prompt" tabindex="-1" id="my-prompt" style="font-size: 14px">
	<div class="am-modal-dialog">
		<div class="am-modal-hd">Amaze UI</div>
		<div class="am-modal-bd">
			来来来，吐槽点啥吧
			<input type="text" class="am-modal-prompt-input">
		</div>
		<div class="am-modal-footer">
			<span class="am-modal-btn" data-am-modal-cancel>取消</span>
			<span class="am-modal-btn" data-am-modal-confirm>提交</span>
		</div>
	</div>
</div>

<script type="text/javascript">
	$(function() {
		$('#doc-prompt-toggle').on('click', function() {
			$('#my-prompt').modal({
				relatedTarget: this,
				onConfirm: function(e) {
					alert('你输入的是：' + e.data || '')
				},
				onCancel: function(e) {
					alert('不想说!');
				}
			});
		});
	   //为了演示，先触发一次click事件
	   $('#doc-prompt-toggle').click();
	});
</script>